<template>
    <view class="p30">
        <view class="cards df jsb mb-30 list" v-for="(item, index) in itemList" :key="index">
            <view class="fs-32 fwb">{{ item.Name }}</view>
            <view @click="download(item)" class="df " style="flex-shrink: 0;color:#2e5be3">
                <uv-icon name="list" color="#2e5be3" size="30rpx"></uv-icon>
                <view class="fs-30">下载</view>
            </view>
        </view>
    </view>
</template>

<script lang="ts" setup>
import { GetPageFile_API } from '@/server/home';
import { getLoginMsg } from '@/utils/util';
const itemList = ref([])
const getPxwjList = async () => {
    const res = await GetPageFile_API({
        AdminCode: getLoginMsg()?.AdminCode,
        TypeCode: 'ZLXZ',
        pageSize: 9999
    })
    if (res.IsSuccess) {
        itemList.value = res.Data.Data
    }

}
const download = (item) => {
    plus.runtime.openURL(item.ThirdUrl);
}

onLoad(() => {
    getPxwjList()
})
</script>

<style lang="scss" scoped>
.list {
    align-items: baseline;
}
</style>
